package models.base;

import play.mvc.Http;

public class ResponseUtility {
    public static void setCorsHeaders() {
        Http.Response.current().setHeader("Access-Control-Allow-Origin", "*");
        Http.Response.current().setHeader("Allow", "*");
        Http.Response.current().setHeader("Access-Control-Allow-Methods", "POST, GET, PATCH, OPTIONS, PUT, DELETE");
        Http.Response.current().setHeader("Access-Control-Allow-Headers", "Origin, X-Requested-With, X-HTTP-Method-Override, Content-Type, Accept, Referrer, User-Agent, x-session, x-authenticity-token, x-platform, room, secret, x-silence, X-Request-Method, js-version , token");
        Http.Response.current().setHeader("Access-Control-Expose-Headers", "js-version, TraceId");
    }
}
